<?php

namespace App\Http\Requests\UserApi\TeacherController;

use Illuminate\Foundation\Http\FormRequest;
use App\Http\Requests\BaseRequest;

class TeacherInfo extends BaseRequest
{
    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        $rules=[
            'teacher_id'=>'required|exists:teacher,id',
        ];

        return $rules;
    }

    public function messages()
    {
        return [
            'teacher_id.required' => 'teacher_id参数必传!',
            'teacher_id.exists' => 'teacher_id参数有误!',
        ];
    }
}
